package com.gxa.eshps.cores.exception;

/**
 * @author Administrator
 */

public enum ExceptionCode {

    /**
     *
     */
    //枚举的值在内存中只有一份

    //SERVER_FAILED("50001");

    //枚举先声明对象
    //访问的时候,只能访问这些提前声明的对象
    // private static final String SERVER FAILED("50001");



    SERVER_FAILED("50001","服务器开小差了,请稍后再试"),
    DUPLICATE_USERNAME("50002","重复的用户名"),
    DUPLICATE_PHONE("50003","重复的手机号"),
    WRONG_EMPTY_PHONE("50036","手机号不能为空"),
    USER_FAILED("50004","用户登录失败,请检查用户手机号或密码"),
    WRONG_PHONE_NUMBER("50005", "手机号格式不正确或手机号错误"),
    SEND_SMS_FAILED("50006","短信发送失败" ),
    DELETE_FAILED("50007","优惠券未核销失败" ),
    EMPTY_TOKEN("50008","TOKEN不能为空"),
    WRONG_TOKEN("50009","token校验不通过"),
    USER_NOT_FOUND("50010","找不到用户"),
    WRONG_PAGE_SIZE("50011","页数，条数必须大于零"),
    ORDERSTATE_UPDATE_FAILD("50020","订单状态异常请稍后再试!"),
    ORDER_NOT_FOUND("50021","还没有订单!"),
    ORDERDETAIL_NOT_FOUND("50022","订单详情显示失败,请稍后再试"),
    COURIER_NOT_FOUND("50031","未找到该配送员"),
    PASSWORD_NOT_ISEMPTY("50032","密码不能为空"),
    COURIER_UPDATE_FAILED("50033","修改密码失败"),
    COURIER_GRABORDER_FAILED("50034","抢单失败"),
    COURIER_SELECT_FAILED("50035","查询失败" ),
    EXPIRE_CODE("50036","验证码已失效"),
    WRONG_CODE("50037","短信验证码错误"),
    WRONG_USER_STATUS("50038","当前用户已冻结"),
    NULL_GOODS("50039","商品已售完"),
    GOODS_NULL("50040","无此商品"),
    OPERATION_FAILED("50041","商品缓存失败");
    private String message;

    private String code;

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }


    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }


    ExceptionCode(String code,String message){
        this.code = code;
        this.message = message;
    }







}
